<html>
 <head>
  <link href="./leetcode-problem.css" rel="stylesheet" type="text/css">
 </head>
 <body>
  <div class="question_difficulty">
   难度：Easy
  </div>
  <div>
   <h1 class="question_title">
    169. Majority Element
   </h1>
   <p>
    Given an array of size
    <i>
     n
    </i>
    , find the majority element. The majority element is the element that appears
    <b>
     more than
    </b>
    <code>
     &lfloor; n/2 &rfloor;
    </code>
    times.
   </p>
   <p>
    You may assume that the array is non-empty and the majority element always exist in the array.
   </p>
   <p>
    <strong>
     Example 1:
    </strong>
   </p>
   <pre>
<strong>Input:</strong> [3,2,3]
<strong>Output:</strong> 3</pre>
   <p>
    <strong>
     Example 2:
    </strong>
   </p>
   <pre>
<strong>Input:</strong> [2,2,1,1,1,2,2]
<strong>Output:</strong> 2
</pre>
  </div>
  <div>
   <h1 class="question_title">
    169. 求众数
   </h1>
   <p>
    给定一个大小为
    <em>
     n
    </em>
    的数组，找到其中的众数。众数是指在数组中出现次数
    <strong>
     大于
    </strong>
    &nbsp;
    <code>
     &lfloor; n/2 &rfloor;
    </code>
    &nbsp;的元素。
   </p>
   <p>
    你可以假设数组是非空的，并且给定的数组总是存在众数。
   </p>
   <p>
    <strong>
     示例&nbsp;1:
    </strong>
   </p>
   <pre><strong>输入:</strong> [3,2,3]
<strong>输出:</strong> 3</pre>
   <p>
    <strong>
     示例&nbsp;2:
    </strong>
   </p>
   <pre><strong>输入:</strong> [2,2,1,1,1,2,2]
<strong>输出:</strong> 2
</pre>
  </div>
 </body>
</html>